/*    */ package org.flashzlm.tools;
/*    */ 
/*    */ import java.util.ArrayList;
import java.util.Date;
import java.util.List;

import org.flashzlm.tools.shifa.ZhanShiFa;
import org.flashzlm.tools.ui.GuaShape;
/*    */ 
/*    */ public class QiYao
/*    */   implements Runnable
/*    */ {
/*    */   private List<Integer> sixYaos;
/* 13 */   private int current = 0;
/*    */   private ZhanShiFa shiFa;
/*    */   private long rapid;
/*    */ 
           private GuaShape guaShape;

           public void setGuaShape(GuaShape guaShape){
        	   this.guaShape=guaShape;
           
           }           
/*    */   public void setRapid(long rapid)
/*    */   {
/* 19 */     this.rapid = rapid; }
/*    */ 
/*    */   public void setShiFa(ZhanShiFa shiFa) {
/* 22 */     this.shiFa = shiFa; }
/*    */ 
/*    */   public int getCurrent() {
/* 25 */     return this.current;
/*    */   }
/*    */ 
/*    */   public List<Integer> getSixYaos() {
/* 29 */     return this.sixYaos;
/*    */   }
/*    */ 
/*    */   public void run()
/*    */   {
				this.sixYaos = new ArrayList<Integer>();
				guaShape.setSixYaos(sixYaos);
/*    */     try
/*    */     {
/* 41 */       this.current += 1;
/* 42 */       Thread.sleep(2L * this.rapid);
/* 43 */       long timeSeed = new Date().getTime();
/* 44 */       int first = this.shiFa.qiYao(timeSeed);
				this.sixYaos.add(Integer.valueOf(first));
                guaShape.setCurrYao(current);
/* 45 */       Thread.sleep(this.rapid);
/*    */ 
/* 47 */       this.current += 1;
/* 48 */       Thread.sleep(2L * this.rapid);
/* 49 */       timeSeed = new Date().getTime();
/* 50 */       int second = this.shiFa.qiYao(timeSeed);
				this.sixYaos.add(Integer.valueOf(second));
				guaShape.setCurrYao(current);
/* 51 */       Thread.sleep(this.rapid);
/*    */ 
/* 53 */       this.current += 1;
/* 54 */       Thread.sleep(2L * this.rapid);
/* 55 */       timeSeed = new Date().getTime();
/* 56 */       int third = this.shiFa.qiYao(timeSeed);
				this.sixYaos.add(Integer.valueOf(third));
				guaShape.setCurrYao(current);
/* 57 */       Thread.sleep(this.rapid);
/*    */ 
/* 59 */       this.current += 1;
/* 60 */       Thread.sleep(2L * this.rapid);
/* 61 */       timeSeed = new Date().getTime();
/* 62 */       int forth = this.shiFa.qiYao(timeSeed);
				this.sixYaos.add(Integer.valueOf(forth));
				guaShape.setCurrYao(current);
/* 63 */       Thread.sleep(this.rapid);
/*    */ 
/* 65 */       this.current += 1;
/* 66 */       Thread.sleep(2L * this.rapid);
/* 67 */       timeSeed = new Date().getTime();
/* 68 */       int fifth = this.shiFa.qiYao(timeSeed);
				this.sixYaos.add(Integer.valueOf(fifth));
				guaShape.setCurrYao(current);
/* 69 */       Thread.sleep(this.rapid);
/*    */ 
/* 71 */       this.current += 1;
/* 72 */       Thread.sleep(2L * this.rapid);
/* 73 */       timeSeed = new Date().getTime();
/* 74 */       int sixth = this.shiFa.qiYao(timeSeed);
				this.sixYaos.add(Integer.valueOf(sixth));
				guaShape.setCurrYao(current);
/* 75 */       Thread.sleep(this.rapid);
   
/* 85 */       this.current += 1;
/*    */     } catch (InterruptedException e) {
/* 87 */       System.out.println("卜卦中断了！");
/*    */     }
/*    */   }
/*    */ }

